import http from '@/plugins/axios'

export function getStopPage(data) {
  return http({
    method: 'POST',
    url: '/ykf/customer/stopPage',
    data
  })
}

export function getHistoryPage(data) {
  return http({
    method: 'POST',
    url: '/ykf/customerShop/historyPage',
    data
  })
}

export function resumeCooperation(data) {
  return http({
    method: 'POST',
    url: '/ykf/customerShop/resumeCooperation',
    data
  })
}

export function removeCustomerShop(data) {
  return http({
    method: 'POST',
    url: '/ykf/customerShop/delete',
    data
  })
}

// 获取员工列表
export function getUserList() {
  return http({
    method: "POST",
    url: '/sys/user/list',
    data: {
      page: { index: 1, size: 9999999999 },
      condition: { keyword: '' }
    }
  }).then(res => {
    return res.list
  })
}

export function updateStopShopInfo(data) {
  return http({
    method: 'POST',
    url: '/ykf/customer/updateStopShopInfo',
    data
  })
}

export function currentCompanyDeptPage() {
  return http({
    method: 'POST',
    url: '/ykf/companyDept/currentCompanyDeptPage',
    data: {
      page: { index: 1, size: 9999999999 },
      condition: {}
    }
  }).then(res => res.list)
}

export function getDepartment() {
  return http({
    method: 'POST',
    url: '/ykf/dictDetail/getDepartment',
    data: {}
  })
}

export function getShopDetail(data) {
  return http({
    method: 'POST',
    url: '/ykf/customerShop/info',
    data
  })
}
